Page({
  data: {
    interval:2000,//轮播图切换间隙
    duration:500,//轮播图切换时长
    imgUrls: [{ url:'https://cdn.qinsilk.com/img/activities/summerGift/summerGift1.png'}],
    types: [{ text: '热门', className:'selectView' }, { text: '益智' }, { text: '休闲' }, { text: '好玩' }],
    gameList: [{ name: "好游戏", imgUrl: "https://cdn.qinsilk.com/img/activities/summerGift/summerGift1.png", introduction: "真的好好玩真的好好玩真的好好玩真的好好玩真的好好玩真的好好玩真的好好玩真的好好玩真的好好玩真的好好玩真的好好玩真的", num: 10000 },{ name: "好游戏", imgUrl: "https://cdn.qinsilk.com/img/activities/summerGift/summerGift1.png", introduction: "真的好好玩真的好好玩真的好好玩真的好好玩真的好好玩真的好好玩真的好好玩真的好好玩真的好好玩真的好好玩真的好好玩真的", num: 10000 }]
   },
 
  onLoad: function () {
    console.log('')
  },
  selectOptionTap: function (event){
    console.log(event.currentTarget.dataset)
    let data=this.data.types.concat([]);
    for(let i=0;i<data.length;i++){
      data[i].className ? data[i].className=undefined:""
    }
    data[event.currentTarget.dataset.index].className ='selectView'
    this.setData({
      types: data
    }
    )
  }, onShareAppMessage: function () {
    console.log("?")
  }
 
})